﻿using System;
using System.Collections;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.Serialization;
using System.ServiceModel;
using System.ServiceModel.Web;
using System.Text;

namespace LunchPad.Service
{
    [DataContract]
    public class Restaurant
    {
        string restaurantID;
        string restaurantCategoryID;
        string restaurantName;
        string imageLocation;
        string lat;
        string lng;

        [DataMember(Name = "RESTAURANT_ID")]
        public string RestaurantID
        {
            get { return restaurantID; }
            set { restaurantID = value; }
        }

        [DataMember(Name = "RESTAURANT_CATEGORY_ID")]
        public string RestaurantCategoryID
        {
            get { return restaurantCategoryID; }
            set { restaurantCategoryID = value; }
        }

        [DataMember(Name = "RESTAURANT_NAME")]
        public string RestaurantName
        {
            get { return restaurantName; }
            set { restaurantName = value; }
        }

        [DataMember(Name = "IMAGE_LOCATION")]
        public string ImageLocation
        {
            get { return imageLocation; }
            set { imageLocation = value; }
        }

        [DataMember(Name = "LAT2")]
        public string Lat
        {
            get { return lat; }
            set { lat = value; }
        }

        [DataMember(Name = "LONG2")]
        public string Lng
        {
            get { return lng; }
            set { lng = value; }
        }

        public Restaurant(RESTAURANT r)
        {
            this.ImageLocation = r.IMAGE_LOCATION;
            this.Lat = r.LAT2.ToString();
            this.lng = r.LONG2.ToString();
            this.RestaurantCategoryID = r.RESTAURANT_CATEGORY_ID.ToString();
            this.RestaurantID = r.RESTAURANT_ID.ToString();
            this.RestaurantName = r.RESTAURANT_NAME.ToString();
        }
    }
}